package trackstacks {

import mx.rpc.soap.mxml.WebService;
import mx.rpc.AbstractService;
import mx.rpc.events.ResultEvent;
import mx.rpc.events.FaultEvent;
import mx.controls.Alert;

public class ServiceLocator {
    public static var jiraURL: String;
    private static var jiraService: WebService;
    public static var jiraLoginToken: String;

    public static function getJiraService(): WebService {
        if (jiraService == null) {
            var js: WebService = new WebService();
            js.wsdl = jiraURL + "/rpc/soap/jirasoapservice-v2?wsdl";
            js.useProxy = false;
            js.showBusyCursor = true;
            js.loadWSDL();
            jiraService = js;
        }
        return jiraService;
    }
}

}